﻿
<!--********************* Part1:Jsp Head *********************-->

<%@ page contentType="text/html;charset=UTF-8"%>  
<%@ include file="/framework/head.jsp"%>

<!--********************* Part2:Java Code *********************-->
<%
	UserPageData obj = (UserPageData)context.getValue("UserPageData");
%>

<!--********************* Part3:JavaScript Code ***************-->
<script language="javascript">

var g_check_items = new Array();
var g_i = 0 ;

g_check_items[g_i++] = new CheckItem("所属仓库","WarehouseCode",true,true,20,false,0);

g_check_items[g_i++] = new CheckItem("用户名","Code",true,true,20,false,0);

g_check_items[g_i++] = new CheckItem("姓名","Name",true,true,20,false,0);

g_check_items[g_i++] = new CheckItem("密码","Password",true,true,20,true,CHECK_ITEM_TYPE_PASSWORD);

g_check_items[g_i++] = new CheckItem("重复密码","RePassword",true,true,20,true,CHECK_ITEM_TYPE_SAME);

//g_check_items[g_i++] = new CheckItem("是否有效","Status",true,true,1,false,0);

g_check_items[g_i++] = new CheckItem("备注","Remark",false,true,500,false,0);


function doSaveAndNew()
{
	if(!CheckInput(g_check_items)) return false;
	SetAction("saveAndNewUser");
	frm.submit();
}
function doSave()
{
	if(!CheckInput(g_check_items)) return false;
	SetAction("saveUser");
	frm.submit();
}
function doCancel()
{
	SetAction("backListUser");
	frm.submit();
}

key_InitDefault();
key_RegSubmitHandler(doSaveAndNew);
</script>

<%=uiBody%>>

<%@ include file="/framework/menu.jsp"%>

<!--********************* Part4:Form  ***************-->

<form id=frm action="<%=Config.getSrv()%>" method="post">
<input type=hidden name="action_code">

<input type=hidden name="Id" value="<%=obj.getId()%>">


<br>

<%=UIManager.addEditHeadTitle("操作员维护")%>


<!--********************* Part5:Edit Area  ***************-->
<%=uiEditStart%>>
<%
	int key_tab = 1 ;
%>


	<%=uiEditTR%>>
		<%=uiEditHeadTD%> width=250>所属仓库：</td>
		<%=uiEditTD%>><!--loginInfo.getLogin-->
			<%=SelectManager.viewWarehouseSelect(con,loginInfo.getLoginWarehouseCode(),"WarehouseCode",obj.viewWarehouseCode(con),false,"","","","key_tab="+(key_tab++))%><font color=red>*</font>
		</td>
	</tr>

	<%=uiEditTR%>>
		<%=uiEditHeadTD%> width=250>用户名：</td>
		<%=uiEditTD%>>
			<input type=text class="texts"  name="Code" size=20  value="<%=obj.viewCode(con)%>" key_tab="<%=key_tab++%>"><font color=red>*</font>
			
		</td>
	</tr>	

	<%=uiEditTR%>>
		<%=uiEditHeadTD%> width=250>姓名：</td>
		<%=uiEditTD%>>
			<input type=text class="texts"  name="Name" size=20  value="<%=obj.viewName(con)%>" key_tab="<%=key_tab++%>"><font color=red>*</font>
		</td>
	</tr>

	<%=uiEditTR%>>
		<%=uiEditHeadTD%> width=250>密码：</td>
		<%=uiEditTD%>>
			<input type=password class="texts"  name="Password" size=20  value="<%=obj.viewPassword(con)%>" key_tab="<%=key_tab++%>"><font color=red>*</font>
			密码由6-16个字符组成，请使用英文字母加数字或符号的组合密码。
		</td>
	</tr>
	
	<%=uiEditTR%>>
		<%=uiEditHeadTD%> width=250>重复密码：</td>
		<%=uiEditTD%>>
			<input type=password class="texts"  name="RePassword" same="Password" size=20  value="<%=obj.viewPassword(con)%>" key_tab="<%=key_tab++%>"><font color=red>*</font>
			请再输入一遍您上面输入的密码。
		</td>
	</tr>

    <%=uiEditTR%>>
        <%=uiEditHeadTD%> width=250>有效性：</td>
        <%=uiEditTD%>>
        <%=SelectManager.viewValidOrNoRadio("Status",obj.viewStatus(con), "key_tab="+(key_tab++)) %><font color=red>*</font>
        </td>
    </tr>
  <!--        <%=uiEditTR%>>
        <%=uiEditHeadTD%> width=250>是否显示进价：</td>
        <%=uiEditTD%>>
        <%=SelectManager.viewValidOrNoRadio("Tel",obj.viewTel(con), "key_tab="+(key_tab++)) %><font color=red>*</font>
        </td>
    </tr>
        <%=uiEditTR%>>
        <%=uiEditHeadTD%> width=250>是否客修用户：</td>
        <%=uiEditTD%>>
        <%=SelectManager.viewValidOrNoRadio("MobilePhone",obj.viewMobilePhone(con), "key_tab="+(key_tab++)) %><font color=red>*</font>
        </td>
    </tr>
    -->
	<%=uiEditTR%>>
		<%=uiEditHeadTD%> width=250>备注：</td>
		<%=uiEditTD%>>
			<textarea cols="50" rows="3" name="Remark" key_tab="<%=key_tab++%>"><%=obj.viewRemark(con)%></textarea>
		</td>
	</tr>
	
<%=uiEditEnd%>

<!--********************* Part6:Action Area  ***************-->
<%=uiCommandStart%>>
	<%=uiCommandTR%>>
   		<%=uiCommandTD%>>                     
			<!--  <input type=button class="buttons" value=" 保存&添加 " onclick="doSaveAndNew();return false;">-->
			<input type=button class="buttons" value="    保存   " onclick="doSave();return false;">
			<input type=button class="buttons" value="    返回   " onclick="doCancel();return false;">
		</td>
	</tr>
<%=uiCommandEnd%>
</form>

<%@ include file="/framework/foot.jsp"%>

<!--
	Author    :justin
	FileName  :/system/base/UserEdit.jsp
-->
